import { ref, computed } from 'vue'
import { defineStore } from 'pinia'

export const useLoginUserStore = defineStore('loginUser', () => {
  const loginUser = ref({
    username: '',
  })
  const fetchLoginUser = async () => {
    // todo 获取登录用户
  }
  const setLoginUser = (newLoginUser:any) => {
    loginUser.value = newLoginUser
  }

  return { loginUser, fetchLoginUser, setLoginUser }
})
